home *** CD-ROM | disk | FTP | other *** search
/ Softwarová Záchrana 3 / Softwarova-zachrana-3.bin / Xteq X-Setup / xqdcXSP-Setup-EN.exe / {app} / plugins / XQ Font Smoothing.xpl < prev    next >
Text File  |  2003-11-27  |  3KB  |  97 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 6.0"
  2. "TYPE"="7"
  3. "COUNT"="3"
  4. "UIPATH"="Appearance\Interface\Font Smooting/Clear Type"
  5. "NAME"="Font Smoothing/ClearType Activated"
  6. "VERSION"="2.01"
  7. "LANGUAGE"="VBScript"
  8. "TEXT 1"="Do not use font smoothing"
  9. "TEXT 2"="Enable default font smoothing"
  10. "TEXT 3"="Enable ClearType (Windows XP and above)"
  11. "DESCRIPTION 1"="When this option is enabled, the edges of large TrueType fonts become anti-aliased. This means that there are no jagged edges to them."
  12. "DESCRIPTION 2"="If you are using Windows XP, you can also enable ClearType, a "new" Font Smoothing method that works even better than the "normal" Font Smoothing but is only suitable for LCD Displays. It looks very strange on normal monitors."
  13. "DESCRIPTION 3"="You can also change these values by using Control Panel -> Display -> Apperance -> Effects"
  14. "DESCRIPTION 4"="If you plan to change these settings often, e.g. if you switch between a normal monitor and a LCD, we suggest the software "ClearTweak" which is available from http://www.ioisland.com/cleartweak/ . It allows you to change the ClearType settings and see the effect immediately."
  15. "AUTHOR"="Xteq Systems"
  16. "CONTACTURL"="http://www.xteq.com/"
  17. "COPYRIGHT"="Copyright ⌐ Xteq Systems - All Rights Reserved"
  18. "COMMENT 1"="Thanks to Steve Day [steve@steveday.net] for the "font smoothing on NT" bug notice!"
  19. "COMMENT 2"="Thanks to RICK-CHERYL [RICK-CHERYL@MMCABLE.COM] for the typo notice!"
  20.  
  21.  
  22. sP1="HKCU\Control Panel\Desktop\FontSmoothing"     'STR!
  23. sP2="HKCU\Control Panel\Desktop\FontSmoothingType" 'DW!
  24. Sub Plugin_Initialize 
  25.  'String
  26.  i1=RegReadValue(sP1)
  27.  i2=RegReadValue(sP2)
  28.  
  29.  if GetWinVer>=6 then 'XP or above
  30.  
  31.     if i1=0 then SetUIElement 1,true
  32.     if i1>0 then 
  33.        if i2=1 then SetUIElement 2,true
  34.        if i2=2 then SetUIElement 3,true
  35.     end if
  36.  
  37.  else 'any other OS
  38.  
  39.     if i=0 then SetUIElement 1,true
  40.     if i=1 or i=2  then SetUIElement 2,true
  41.  
  42.  end if
  43.  
  44. End Sub
  45.  
  46. Sub Plugin_Apply(ElementIndex,ElementSubIndex)
  47.  vVal1=-1
  48.  vVal2=-1
  49.  
  50.  if GetUIElement(1)=true then
  51.     vVal1=0
  52.     vVal2=0
  53.  
  54.  elseif GetUIElement(2)=true then
  55.     'only on Win 9x and ME this is "1"
  56.     if GetWinVer=1 or GetWinVer=3 or GetWinVer=5 then
  57.        vVal1=1
  58.        vVal2=1 
  59.     else
  60.        vVal1=2
  61.        vVal2=1
  62.     end if
  63.  
  64.  elseif GetUIElement(3)=true then
  65.     'on XP only!
  66.     if GetWinVer>=6 then
  67.        vVal1=2
  68.        vVal2=2 
  69.     else
  70.        vVal1=-1
  71.        vVal2=-1
  72.        Call MsgError("Clear Type can be enabled on Windows XP or above only, please make a different selection!") 
  73.     end if
  74.  end if
  75.  
  76.  
  77.  if vVal1>-1 then
  78.     Call RegWriteValue(sP1,vVal1,1)
  79.     Call RegWriteValue(sP2,vVal2,2)
  80.  
  81.     'only on Win 9x and ME
  82.     if GetWinVer=1 or GetWinVer=3 or GetWinVer=5 then
  83.        Call IniWriteValue("WIN.INI","TrueType","FontSmoothing",vVal1)
  84.     end if
  85.  
  86.     Call Restart()
  87.  end if
  88.  
  89. End Sub
  90.  
  91.  
  92. Sub Plugin_Terminate 
  93. End Sub
  94.  
  95.  
  96.  
  97.